﻿using CowsAndBulls;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using System;

namespace TestCowsAndBulls
{
    [TestClass()]
    public class PlayerTest
    {
        [TestMethod()]
        public void GuessNumberTestCorrect()
        {
            Player target = new Player();
            bool expected = true;
            bool actual;
            actual = target.GuessNumber("1234");
            Assert.AreEqual(expected, actual);
            Assert.AreEqual(target.EnteredCommand, false);
        }

        [TestMethod()]
        public void GuessNumberTestBugNumber()
        {
            Player target = new Player();
            bool expected = false;
            bool actual;
            actual = target.GuessNumber("12345");
            Assert.AreEqual(expected, actual);
            Assert.AreEqual(target.EnteredCommand, false);
        }

        [TestMethod()]
        public void GuessNumberTestCommand()
        {
            Player target = new Player();
            bool expected = true;
            bool actual;
            actual = target.GuessNumber("asdf");
            Assert.AreEqual(expected, actual);
            Assert.AreEqual(target.EnteredCommand, true);
            Assert.AreEqual(target.Command, "asdf");
        }
    }
}
